home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
BCI NET
/
BCI NET Dec 94.iso
/
archives
/
telecomm
/
bbs
/
maxsdoors2.lha
/
OutBndCnt001.lha
/
OutboundControl
/
docs
/
OutboundControl.DOC
< prev
next >
Wrap
Text File
|
1992-09-20
|
5KB
|
138 lines
OutboundControl v 0.01 Sept '92.
----------------------------------
Q: Who is this program for?
MAXSBBS users that are into heavy-duty mail processing, and
in particular, those that are exporting large amounts of mail.
Q: Background?
Having recently been away for 3 months, I was going nuts trying
to figure out why the BBS HD kept filling up while I was away.
Before I left, I made all sorts of scripts to automatically
process incoming nodelist and other stuff, to ensure that
something like this couldn't happen.
My flatmate told me there was a Disk Full requestor. By phone,
(I didn't have access to a modem), she was instructed to
delete suspicious files, particularily in my inbound dir.
(Once, the BBS itelf got deleted, but that's another story...)
We started with the T: directory. A week later, we had to get
rid of my Games: directory. And so on. The nodelist (1.5MB)
got killed as well. And the HD _still_ kept filling up...
And the phone bills got bigger and bigger...
Even when I was back in Oz, it took me a week to find the reason.
I run all mail processing on a background node, as I can't really
have the BBS offline for 2 hours/day for tossing mail.
This node has to use its own separate configuration file (reason
being that it has to import on a set time, whereas the other node
is not allowed to touch the mail at all. Indeed, node1 would
happily attempt to import the mail if given half a chance, but would
instantly kill it, since MAXS cannot handle ARC mail real well.)
Anyway, the bgrd node was set up to export mail to a point, which I'd
pretty much forgotten about. The point had decided not to collect any
further mail (and I think I was told about this aat some stage, so
it's really my own fault), but maxs was still exporting to them.
So, by the time I found this out, the outbound packet to this node
had built up to 16 (sixteen) MEGABYTES!. I thought I had a fair bit
of room on my Work: partition before I left, but not THAT much 8-).
Q: Get to the point, I havent got all day?!
Ok, well, anyway, this here (attached) is a set of script files that
will check your outbound directories size and notify you if they are
too big (configurable).
Q: How do I install it?
Put the scriptfiles in BBS:Scripts (better make that dir up if you
don't already have one...).
Copy Tsize to C:
Copy SYSLOG to C: if you want a log to be updated,
if not, jsut ignore this one.
It's possibly you already have syslog or tsize of course, in
which case, fine.
Similar programs may also work. Note Tsize will give the size of a dir
in _bytes_, so make sure your program does the same.
Tsize will print too much garbage (thus confusing the script)
if you are not at the bottommost level of a directory tree.
The script takes care of this, as long as you dont have any
strange directories INSIDE your various outbounds?!
BTW BBS:FIDONET/OUTBOUND is used as the path beginning.
(If this is unacceptable in your case, let me know...)
Execute the scriptfiles from a systemevent, or
run crontab to execute various tasks at set times/days.
Cybercron (included is WB2 only, as MAY the script be as well).
Outboundcontrol will look for all your subdirectories under
outbound, regardless of how many there are. (in other words,
even those old ones that may not be used by maxs anymore will
still be checked).
the only parameter is the max size allowed in Kbytes, ie
EXECUTE BBS:Scripts/outboundcontrol 2000
will run the script, with a limit of 2Megabytes (2000K).
(Default value is 2500 K)
IF any dir contains more than this, the program will display
this info in the CLI window. Also, it will be written to
S:System.log if my prg could find SYSLOG in C:
So far, the program will only serve as a handy warning method.
For completely unattended operation, also put the outboundcontrol-C
script with the others.
This script is called from the first scripts each time a directory
is over the limit. The directory name is passed as a parameter, so
it's then up to you to decide what to with it.
The sample file simply deletes everything in that directory,
(NOTE: For security, I have commented out 'delete' from the script.)
This is also the place if you want to change the script so that it
will provide one (or more?) exceptions to the limit. Or make it
delete certain files in preferences of others, perhaps nodelists?
You could attempt to delete the oldest files, but this will not
work smoothly with mail packets, as the filedate is updated
each time something is added to the archive.
Anyway, look at outboundcontrol-C and edit as desired. If you feel
you must tinker with the other scripts, let me know, please send
me a copy. Really, youd be better of not touching them, I think!
Ok, that's about it. Any probs, let me know! Mr Fax BBS, 3:711/509
Maxsnet 3:30000/70, Worldnet 61:9600/333.
Phone: 02-9294407 voice, 02-9556681 BBS (V32bis)
Michael Borgefjord